import request from '@/utils/request'

// 查询金积分兑换码列表
export function listPriceExchange(query) {
  return request({
    url: '/admin/priceExchange/list',
    method: 'get',
    params: query
  })
}

// 查询金积分兑换码详细
export function getPriceExchange(id) {
  return request({
    url: '/admin/priceExchange/' + id,
    method: 'get'
  })
}

// 新增金积分兑换码
export function addPriceExchange(data) {
  return request({
    url: '/admin/priceExchange',
    method: 'post',
    data: data
  })
}

// 修改金积分兑换码
export function updatePriceExchange(data) {
  return request({
    url: '/admin/priceExchange',
    method: 'put',
    data: data
  })
}

// 删除金积分兑换码
export function delPriceExchange(id) {
  return request({
    url: '/admin/priceExchange/' + id,
    method: 'delete'
  })
}
